package bean;

public class Product {
    protected int Pid; // 自增主键
    protected String name; // 商品名称
    protected int classification; // 所属分类
    protected String productDescription; // 商品描述
    protected double price; // 一个商品的价格
    protected int Sid; // 商店id
    protected String image_url; // 商品的图片

    @Override
    public String toString() {
        return "Product{" +
                "Pid=" + Pid +
                ", name='" + name + '\'' +
                ", classification=" + classification +
                ", productDescription=" + productDescription +
                ", price=" + price +
                ", Sid=" + Sid +
                ", image_url='" + image_url + '\'' +
                '}';
    }

    public Product() {
    }

    public Product(Product product) {
        Pid = product.getPid();
        this.name = product.getName();
        this.classification = product.classification;
        this.productDescription = product.getProductDescription();
        this.price = product.getPrice();
        Sid = product.getSid();
        this.image_url = product.getImage_url();
    }





    public int getPid() {
        return Pid;
    }

    public void setPid(int pid) {
        Pid = pid;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public int getClassification() {
        return classification;
    }

    public void setClassification(int classification) {
        this.classification = classification;
    }

    public String getProductDescription() {
        return productDescription;
    }

    public void setProductDescription(String productDescription) {
        this.productDescription = productDescription;
    }

    public double getPrice() {
        return price;
    }

    public void setPrice(double price) {
        this.price = price;
    }

    public int getSid() {
        return Sid;
    }

    public void setSid(int sid) {
        Sid = sid;
    }

    public String getImage_url() {
        return image_url;
    }

    public void setImage_url(String image_url) {
        this.image_url = image_url;
    }
}
